﻿using System;
using SharpSqlAnalyzer.nodes;
using SharpSqlAnalyzer.nodes.hive;

namespace SharpSqlAnalyzer.stmt.hive
{
	// Token: 0x020001C2 RID: 450
	public class THiveLoad : TCustomSqlStatement
	{
		// Token: 0x06000EFF RID: 3839 RVA: 0x0030AEC0 File Offset: 0x003090C0
		public THiveLoad(EDbVendor dbvendor) : base(dbvendor)
		{
			this.sqlstatementtype = ESqlStatementType.ssthiveLoad;
		}

		// Token: 0x170002C1 RID: 705
		// (get) Token: 0x06000F00 RID: 3840 RVA: 0x0030AED4 File Offset: 0x003090D4
		// (set) Token: 0x06000F01 RID: 3841 RVA: 0x0030AEDC File Offset: 0x003090DC
		public virtual bool Islocal
		{
			get
			{
				return this.islocal;
			}
			set
			{
				this.islocal = value;
			}
		}

		// Token: 0x170002C2 RID: 706
		// (get) Token: 0x06000F02 RID: 3842 RVA: 0x0030AEE5 File Offset: 0x003090E5
		// (set) Token: 0x06000F03 RID: 3843 RVA: 0x0030AEED File Offset: 0x003090ED
		public virtual bool Isoverwrite
		{
			get
			{
				return this.isoverwrite;
			}
			set
			{
				this.isoverwrite = value;
			}
		}

		// Token: 0x170002C3 RID: 707
		// (get) Token: 0x06000F04 RID: 3844 RVA: 0x0030AEF6 File Offset: 0x003090F6
		// (set) Token: 0x06000F05 RID: 3845 RVA: 0x0030AEFE File Offset: 0x003090FE
		public virtual TObjectName Path
		{
			get
			{
				return this.path;
			}
			set
			{
				this.path = value;
			}
		}

		// Token: 0x170002C4 RID: 708
		// (get) Token: 0x06000F06 RID: 3846 RVA: 0x0030AF07 File Offset: 0x00309107
		// (set) Token: 0x06000F07 RID: 3847 RVA: 0x0030AF0F File Offset: 0x0030910F
		public virtual TTable Table
		{
			get
			{
				return this.table;
			}
			set
			{
				this.table = value;
			}
		}

		// Token: 0x06000F08 RID: 3848 RVA: 0x0030AF18 File Offset: 0x00309118
		public override int doParseStatement(TCustomSqlStatement psql)
		{
			if (this.rootNode == null)
			{
				return -1;
			}
			base.doParseStatement(psql);
			THiveLoadSqlNode thiveLoadSqlNode = (THiveLoadSqlNode)this.rootNode;
			this.islocal = thiveLoadSqlNode.Islocal;
			this.isoverwrite = thiveLoadSqlNode.Isoverwrite;
			this.path = thiveLoadSqlNode.Path;
			this.table = this.analyzeFromTable(thiveLoadSqlNode.FromTable, new bool?(true));
			return 0;
		}

		// Token: 0x06000F09 RID: 3849 RVA: 0x0030AF80 File Offset: 0x00309180
		public override void accept(TParseTreeVisitor v)
		{
			v.preVisit(this);
			v.postVisit(this);
		}

		// Token: 0x06000F0A RID: 3850 RVA: 0x0030AF90 File Offset: 0x00309190
		public override void acceptChildren(TParseTreeVisitor v)
		{
			v.preVisit(this);
			v.postVisit(this);
		}

		// Token: 0x04001353 RID: 4947
		private bool islocal;

		// Token: 0x04001354 RID: 4948
		private bool isoverwrite;

		// Token: 0x04001355 RID: 4949
		private TObjectName path;

		// Token: 0x04001356 RID: 4950
		private TTable table;
	}
}
